import logging
import unittest
from htmltestreport import HTMLTestReport

from common.logging_use import init_log_config
from config import BASE_DIR
from scripts.test_ihrm_add_emp_params import TestIhrmEmpAddParams

from scripts.test_ihrm_login_params import TestIhrmLoginParams

#初始化日志信息
init_log_config(BASE_DIR + "./log/ihrm.log")

suite = unittest.TestSuite()
#生成日志
logging.info("生成套件成功")

suite.addTest(unittest.makeSuite(TestIhrmEmpAddParams))

suite.addTest(unittest.makeSuite(TestIhrmLoginParams))
runner = HTMLTestReport('/report/ihrm.html','人力资源管理系统')
runner.run(suite)
logging.info("生成报告成功")